<?php $this -> load -> view('adminx/header'); ?>
<!-- BEGIN CONTAINER -->
<div class="page-container">
	<!-- BEGIN SIDEBAR -->
	<?php $this -> load -> view('adminx/mune'); ?>
	<!-- END SIDEBAR -->
	<!-- BEGIN CONTENT -->
	<div class="page-content-wrapper">
		<div class="page-content">
			<!-- BEGIN SAMPLE PORTLET CONFIGURATION MODAL FORM-->
			<!-- /.modal -->
			<h3 class="page-title"> <?php echo $title; ?> <small><?php echo $en; ?></small></h3>
			<div class="page-bar">
				<ul class="page-breadcrumb">
					<li>
						<i class="fa fa-home"></i>
						<a href="/adminx">首页</a>
						<i class="fa fa-angle-right"></i>
					</li>
					<li>
						<a href="#"><?php echo $title; ?></a>
					</li>
				</ul>
			</div>
			<!-- END PAGE HEADER-->
			<div class="clearfix"></div>
			<div class="row">
				<div class="col-md-12 col-sm-12">
					<div class="panel panel-default">
			<div class="panel-heading">
				<?php echo $title; ?>
			</div>
			<div class="panel-body">
				<p><img width="120" src="<?php echo ($m['headimgurl']?$m['headimgurl']:'/mex/lance/img/tx.jpg'); ?>" /></p>
				<p id="name">姓名：<?php echo $m['name']; ?></p>
				<p>昵称：<?php echo $m['nickname']; ?></p>
				<p>性别：<?php echo $m['sex']==1?'男':'女'; ?></p>
				<p>地址：<?php echo $m['country'],' ',$m['province'],' ',$m['city'],' ',$m['zz']; ?></p>
				<p>手机：<?php echo $m['phone']; ?></p>
				<p>邮箱：<?php echo $m['email']; ?></p>
				<p>总提现：<?php echo $zj_tx?$zj_tx:'0'; ?></p>
				<p>总收益：<?php echo $zj_zsy?$zj_zsy:'0'; ?></p>
				<p class="text-danger">可提现金额：<?php echo $zj_sy?$zj_sy:'0'; ?></p>
			</div>
		</div>
		
		<ul id="myTab" class="nav nav-tabs">
			<li class="active">
				<a href="#syjl" data-toggle="tab">收益记录</a>
			</li>
			<li class="">
				<a href="#fs" data-toggle="tab">粉丝</a>
			</li>
			<li class="">
				<a href="#wx_lt" onclick="get_wx_lt()" data-toggle="tab">聊天</a>
			</li>
		</ul>
		<div id="myTabContent" class="tab-content">
			<div class="tab-pane fade active in" id="syjl">
				<table class="table table-hover table-responsive">
					<thead>
						<tr>
							<th>项目</th>
							<th>内容</th>
							<th>金额</th>
							<th>时间</th>
							<th>状态</th>
						</tr>
					</thead>
					<tbody>
						<?php
		$state[1] = '正常';
		$state[2] = '待处理';
		$state[-1] = '作废';

		$type[-1] = '提现';
		$type[-2] = '购物';
		$type[-3] = '活动';
		$type[-4] = '竞拍';
		$type[0] = '未定义';
		$type[1] = '充值';
		$type[2] = '粉丝红包';
		$type[3] = '礼券';
		$type[4] = '销售收益';
						 foreach($bill as $v){ ?>
						<tr>
							<td><?php echo $type[$v['type']]; ?></td>
							<td><?php echo $v['content']; ?></td>
							<td><?php echo $v['je']; ?></td>
							<td><?php echo date('Y-m-d H:i',$v['mktime']); ?></td>
							<td><?php echo $state[$v['state']]; ?></td>
						</tr>
						<?php } ?>
					</tbody>
				</table>

			</div>			
			<div class="tab-pane fade" id="fs">
			<table class="table table-hover table-responsive">
					<thead>
						<tr>
							<th>粉丝头像</th>
							<th>粉丝昵称</th>
							<th>关注时间</th>
						</tr>
					</thead>
					<tbody>
						<?php foreach($fs as $v){  ?>
						<tr>
							<td ><img width="50" src="<?php echo $v['headimgurl']; ?>" /></td>
							<td><?php echo $v['nickname']; ?></td>
							<td><?php echo date('Y-m-d H:i',$v['subscribe_time']); ?></td>
						</tr>
						<?php } ?>
					</tbody>
				</table>
	</div>
	       <div class="tab-pane fade" id="wx_lt">
	       	<div class="panel panel-default">
				<div class="panel-heading">
					会员管理
				</div>
				<div class="panel-body">
					<form role="form" class="form-inline">
						<div class="form-group" pd="no_empty">
							<input type="text" class="form-control" id="key" name="key" placeholder="会员关键字">
						</div>
						<div class="form-group" pd="no_empty">
							<select onchange="get_wx_lt()" name="page" id="page" class="form-control" placeholder="当前页" title="当前页"></select>
						</div>
						<select onchange="get_wx_lt()" style="width: 100px;" class="form-control" id="state">
							<option value="0">全部</option>
							<option value="1">未回复</option>
							<option value="2">已经回复</option>
						</select>
						<select onchange="get_wx_lt()" style="width: 100px;" class="form-control" id="MsgType">
							<option value="0">全部</option>
							<option value="text">文字</option>
							<option value="voice">语音</option>
							<option value="image">图片</option>
							<option value="location">位置</option>
							<option value="link">链接</option>
							<option value="event">事件</option>
						</select>
						<button onclick="get_wx_lt()" type="button" class="button button-pill">
							检索
						</button>
						<button onclick="show_wx_ks('<?php echo $m['openid']; ?>','<?php echo $m['nickname']; ?>')" type="button" class="button  button-pill button-caution">快速回复</button>
					</form>
				</div>
			</div>
	       	<table class="table table-hover table-responsive">
					<thead>
						<tr>
							<th>头像</th>
							<th>昵称</th>
							<th>类型</th>
							<th>内容</th>
							<th>时间</th>
							<th>状态</th>
						</tr>
					</thead>
					<tbody id="get_wx_lt">
					</tbody>
				</table>
	       </div>
		</div>
				</div>
			</div>
		</div>
	</div>
	

	<!-- BEGIN QUICK SIDEBAR -->
	<?php $this -> load -> view('adminx/lt'); ?>
	<!-- END QUICK SIDEBAR -->
</div>
<!-- END CONTAINER -->
<!-- BEGIN FOOTER -->
<?php $this -> load -> view('adminx/footer'); ?>